package com.ziytek.web.citizen.model.rsp;

import com.ziytek.web.citizen.constant.ServerConstant;
import lombok.Data;

/**
 * @author fengh
 */
@Data
public class R {

    private String code;
    private String message;

    public R(String code, String message) {
        this.code = code;
        this.message = message;
    }

    public static R fail(String message) {
        return new R("200", message);
    }

    public static R success(String message) {
        return new R(ServerConstant.SUCCESS, message);
    }
}
